package cxbks.java;

import lombok.extern.slf4j.Slf4j;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.data.mongodb.config.EnableMongoAuditing;

/**
 * @Author:
 * @CreateTime: 2021-09-09 15:45
 * @Description:
 */
@Slf4j
//在启动类中添加@EnableMongoAuditing注解使@CreatedDate和@LastModifiedDate生效
@EnableMongoAuditing
@SpringBootApplication
public class MongoDBApplication {

	public static void main(String[] args) {
		SpringApplication.run(MongoDBApplication.class, args);
		log.info("learn-mongodb项目启动完成");
	}
}
